def count_sort(array=[]):
    min,max = array[0],array[0]
    for i in  array:
        if i<min:
            min = i
        if i>max:
            max = i
    array_length = max-min+1
    new_array = [0]*array_length
    for index in array:
        new_array[index-min] +=1
    index = 0
    for a in range(array_length):
        for c in range(new_array[a]):
            array[index] = a+min
            index+=1
    return  array


array = [55,43,32,55,34,30,23,44]

count_sort(array)

print(array)
